package com.iplant.wms.service.po.wms;

import com.fasterxml.jackson.annotation.JsonProperty;;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

/**
 * 仓库库存 /库区库存 / 库位库存
 * <p>
 * 非DB数据结构
 *
 * @author ShrisJava
 */
public class WMSStock implements Serializable {
    private static final long serialVersionUID = 1L;
    /**
     * 主键
     */
    public int ID = 0;

    public int FactoryID = 0;

    public String FactoryCode = "";
    public String FactoryName = "";

    public int StoreID = 0;

    public String StoreCode = "";
    public String StoreName = "";

    public int StoreTypeID = 0;

    public String StoreTypeCode = "";
    public String StoreTypeName = "";

    public int StoreRegionID = 0;

    public String StoreRegionCode = "";
    public String StoreRegionName = "";

    public int StoreAreaID = 0;

    public String StoreAreaCode = "";
    public String StoreAreaName = "";

    public int StoreShelfID = 0;

    public String StoreShelfCode = "";
    public String StoreShelfName = "";

    public int StoreStationID = 0;

    public String StoreStationCode = "";
    public String StoreStationName = "";

    public int MaterialID = 0;

    public String MaterialCode = "";

    public String MaterialName = "";


    public int UnitID = 0;

    public String UnitCode = "";

    public String UnitText = "";


    public double MaterialNum = 0.0;

    public double FreezeNum = 0.0;

    /**
     * 可用库存数
     */
    public double AvailableStock = 0.0;

    public List<WMSStockRecord> StockRecordList = new ArrayList<>();

    public WMSStock() {
    }

    @JsonProperty("FactoryID")
    public int getFactoryID() {
        return FactoryID;
    }

    public void setFactoryID(int factoryID) {
        FactoryID = factoryID;
    }

    @JsonProperty("FactoryCode")
    public String getFactoryCode() {
        return FactoryCode;
    }

    public void setFactoryCode(String factoryCode) {
        FactoryCode = factoryCode;
    }

    @JsonProperty("FactoryName")
    public String getFactoryName() {
        return FactoryName;
    }

    public void setFactoryName(String factoryName) {
        FactoryName = factoryName;
    }

    @JsonProperty("StoreID")
    public int getStoreID() {
        return StoreID;
    }

    public void setStoreID(int storeID) {
        StoreID = storeID;
    }

    @JsonProperty("StoreCode")
    public String getStoreCode() {
        return StoreCode;
    }

    public void setStoreCode(String storeCode) {
        StoreCode = storeCode;
    }

    @JsonProperty("StoreName")
    public String getStoreName() {
        return StoreName;
    }

    public void setStoreName(String storeName) {
        StoreName = storeName;
    }

    @JsonProperty("StoreTypeID")
    public int getStoreTypeID() {
        return StoreTypeID;
    }

    public void setStoreTypeID(int storeTypeID) {
        StoreTypeID = storeTypeID;
    }

    @JsonProperty("StoreTypeCode")
    public String getStoreTypeCode() {
        return StoreTypeCode;
    }

    public void setStoreTypeCode(String storeTypeCode) {
        StoreTypeCode = storeTypeCode;
    }

    @JsonProperty("StoreTypeName")
    public String getStoreTypeName() {
        return StoreTypeName;
    }

    public void setStoreTypeName(String storeTypeName) {
        StoreTypeName = storeTypeName;
    }

    @JsonProperty("StoreAreaID")
    public int getStoreAreaID() {
        return StoreAreaID;
    }

    public void setStoreAreaID(int storeAreaID) {
        StoreAreaID = storeAreaID;
    }

    @JsonProperty("StoreAreaCode")
    public String getStoreAreaCode() {
        return StoreAreaCode;
    }

    public void setStoreAreaCode(String storeAreaCode) {
        StoreAreaCode = storeAreaCode;
    }

    @JsonProperty("StoreAreaName")
    public String getStoreAreaName() {
        return StoreAreaName;
    }

    public void setStoreAreaName(String storeAreaName) {
        StoreAreaName = storeAreaName;
    }

    @JsonProperty("StoreStationID")
    public int getStoreStationID() {
        return StoreStationID;
    }

    public void setStoreStationID(int storeStationID) {
        StoreStationID = storeStationID;
    }

    @JsonProperty("StoreStationCode")
    public String getStoreStationCode() {
        return StoreStationCode;
    }

    public void setStoreStationCode(String storeStationCode) {
        StoreStationCode = storeStationCode;
    }

    @JsonProperty("StoreStationName")
    public String getStoreStationName() {
        return StoreStationName;
    }

    public void setStoreStationName(String storeStationName) {
        StoreStationName = storeStationName;
    }

    @JsonProperty("MaterialID")
    public int getMaterialID() {
        return MaterialID;
    }

    public void setMaterialID(int materialID) {
        MaterialID = materialID;
    }

    @JsonProperty("MaterialCode")
    public String getMaterialCode() {
        return MaterialCode;
    }

    public void setMaterialCode(String materialCode) {
        MaterialCode = materialCode;
    }

    @JsonProperty("MaterialName")
    public String getMaterialName() {
        return MaterialName;
    }

    public void setMaterialName(String materialName) {
        MaterialName = materialName;
    }

    @JsonProperty("MaterialNum")
    public double getMaterialNum() {
        return MaterialNum;
    }

    public void setMaterialNum(double materialNum) {
        MaterialNum = materialNum;
    }


    @JsonProperty("UnitID")
    public int getUnitID() {
        return UnitID;
    }

    public void setUnitID(int unitID) {
        UnitID = unitID;
    }

    @JsonProperty("UnitCode")
    public String getUnitCode() {
        return UnitCode;
    }

    public void setUnitCode(String unitCode) {
        UnitCode = unitCode;
    }

    @JsonProperty("UnitText")
    public String getUnitText() {
        return UnitText;
    }

    public void setUnitText(String unitText) {
        UnitText = unitText;
    }

    @JsonProperty("StoreShelfID")
    public int getStoreShelfID() {
        return StoreShelfID;
    }

    public void setStoreShelfID(int storeShelfID) {
        StoreShelfID = storeShelfID;
    }

    @JsonProperty("StoreShelfCode")
    public String getStoreShelfCode() {
        return StoreShelfCode;
    }

    public void setStoreShelfCode(String storeShelfCode) {
        StoreShelfCode = storeShelfCode;
    }

    @JsonProperty("StoreShelfName")
    public String getStoreShelfName() {
        return StoreShelfName;
    }

    public void setStoreShelfName(String storeShelfName) {
        StoreShelfName = storeShelfName;
    }


    @JsonProperty("FreezeNum")
    public double getFreezeNum() {
        return FreezeNum;
    }

    public void setFreezeNum(double freezeNum) {
        FreezeNum = freezeNum;
    }


    @JsonProperty("ID")
    public int getID() {
        return ID;
    }

    public void setID(int ID) {
        this.ID = ID;
    }

    @JsonProperty("AvailableStock")
    public double getAvailableStock() {
        AvailableStock = MaterialNum - FreezeNum;
        return AvailableStock;
    }

    public void setAvailableStock(double availableStock) {
        AvailableStock = availableStock;
    }

    @JsonProperty("StoreRegionD")
    public int getStoreRegionID() {
        return StoreRegionID;
    }

    public void setStoreRegionID(int storeRegionID) {
        StoreRegionID = storeRegionID;
    }

    @JsonProperty("StoreRegionCode")
    public String getStoreRegionCode() {
        return StoreRegionCode;
    }

    public void setStoreRegionCode(String storeRegionCode) {
        StoreRegionCode = storeRegionCode;
    }

    @JsonProperty("StoreRegionName")
    public String getStoreRegionName() {
        return StoreRegionName;
    }

    public void setStoreRegionName(String storeRegionName) {
        StoreRegionName = storeRegionName;
    }

    @JsonProperty("StockRecordList")
    public List<WMSStockRecord> getStockRecordList() {
        return StockRecordList;
    }

    public void setStockRecordList(List<WMSStockRecord> stockRecordList) {
        StockRecordList = stockRecordList;
    }
}
